package com.johnsoft.pph.gui;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JButton;

import com.johnsoft.pph.Installer;

public class SSFileButton extends JButton implements ActionListener {
	
	String filename;
	
	public SSFileButton(String s)
	{
		filename = s;
		this.setText(s.substring(0, s.length() - 4));
		addActionListener(this);
	}
	
	public void actionPerformed(ActionEvent e)
	{
		if (e.getSource() != this)
			return;
		Installer.setup.setInstall(filename);
		Installer.setup.setGUI(new GuiInstall());
	}
}
